import http from "@/http"
import type { favoriteTable } from "./favoriteTable"

//添加收藏
export const addFavoriteApi  = (parm:favoriteTable)=>{
    return http.post("/api/favorite/addfavorite",parm)
}
//分页查询收藏
export const selectFavoriteApi  = (userId:string,page:number,pageSize:number)=>{
    return http.get("/api/favorite/selectFavorite",{userId,page,pageSize})
}
//删除收藏
export const deleteFavoriteApi = (favoriteId:string)=>{
    return http.delete(`/api/favorite/delete/${favoriteId}`)
}